package com.mtx.weatherreport.bean;

import com.mtx.weatherreport.R;

/**
 * @author yinghuayu
 * @create 2018/2/26.
 */

public class TodayWeather {
    private String mCityName;
    private String mCity;  // 城市名称
    private String mTime;  // 更新时间
    private String mWet;  // 湿度
    private String mPm;  // PM2.5的值
    private String mPmquality;  // 空气质量
    private String mWeek;  // 星期
    private String mHigh;  // 高温
    private String mLow;  // 低温
    private String mClimate;  // 多云转晴
    private String mWind;    // 风力

    public String getmCityName() {
        return mCityName;
    }

    public void setmCityName(String mCityName) {
        this.mCityName = mCityName;
    }

    public String getmCity() {
        return mCity;
    }

    public void setmCity(String mCity) {
        this.mCity = mCity;
    }

    public String getmTime() {
        return mTime;
    }

    public void setmTime(String mTime) {
        this.mTime = mTime;
    }

    public String getmWet() {
        return mWet;
    }

    public void setmWet(String mWet) {
        this.mWet = mWet;
    }

    public String getmPm() {
        return mPm;
    }

    public void setmPm(String mPm) {
        this.mPm = mPm;
    }

    public String getmPmquality() {
        return mPmquality;
    }

    public void setmPmquality(String mPmquality) {
        this.mPmquality = mPmquality;
    }

    public String getmWeek() {
        return mWeek;
    }

    public void setmWeek(String mWeek) {
        this.mWeek = mWeek;
    }

    public String getmHigh() {
        return mHigh;
    }

    public void setmHigh(String mHigh) {
        this.mHigh = mHigh;
    }

    public String getmLow() {
        return mLow;
    }

    public void setmLow(String mLow) {
        this.mLow = mLow;
    }

    public String getmClimate() {
        return mClimate;
    }

    public void setmClimate(String mClimate) {
        this.mClimate = mClimate;
    }

    public String getmWind() {
        return mWind;
    }

    public void setmWind(String mWind) {
        this.mWind = mWind;
    }

    @Override
    public String toString() {
        return "TodayWeather{" +
                "city_name='" + mCityName + '\'' +
                ", city='" + mCity + '\'' +
                ", time='" + mTime + '\'' +
                ", wet='" + mWet + '\'' +
                ", pm='" + mPm + '\'' +
                ", pmquality='" + mPmquality + '\'' +
                ", week='" + mWeek + '\'' +
                ", high='" + mHigh + '\'' +
                ", low='" + mLow + '\'' +
                ", climate='" + mClimate + '\'' +
                ", wind='" + mWind + '\'' +
                '}';
    }

    /**
     * 天气状况图标
     * @param str
     * @return
     */
    public int getImageWeather(String str){
        int weather_image_id=1;

        switch (str)
        {
            case "暴雪":
                weather_image_id= R.drawable.biz_plugin_weather_baoxue;
                break;
            case "暴雨":
                weather_image_id=R.drawable.biz_plugin_weather_baoyu;
                break;
            case "大暴雨":
                weather_image_id=R.drawable.biz_plugin_weather_dabaoyu;
                break;
            case "大雪":
                weather_image_id=R.drawable.biz_plugin_weather_daxue;
                break;
            case "大雨":
                weather_image_id=R.drawable.biz_plugin_weather_dayu;
                break;
            case "多云":
                weather_image_id=R.drawable.biz_plugin_weather_duoyun;
                break;
            case "雷阵雨":
                weather_image_id=R.drawable.biz_plugin_weather_leizhenyu;
                break;
            case "雷阵雨冰雹":
                weather_image_id=R.drawable.biz_plugin_weather_leizhenyubingbao;
                break;
            case "晴":
                weather_image_id=R.drawable.biz_plugin_weather_qing;
                break;
            case "沙尘暴":
                weather_image_id=R.drawable.biz_plugin_weather_shachenbao;
                break;
            case "特大暴雨":
                weather_image_id=R.drawable.biz_plugin_weather_tedabaoyu;
                break;
            case "小雪":
                weather_image_id=R.drawable.biz_plugin_weather_xiaoxue;
                break;
            case "小雨":
                weather_image_id=R.drawable.biz_plugin_weather_xiaoyu;
                break;
            case "阴":
                weather_image_id=R.drawable.biz_plugin_weather_yin;
                break;
            case "雨夹雪":
                weather_image_id=R.drawable.biz_plugin_weather_yujiaxue;
                break;
            case "阵雪":
                weather_image_id=R.drawable.biz_plugin_weather_zhenxue;
                break;
            case "阵雨":
                weather_image_id=R.drawable.biz_plugin_weather_zhenyu;
                break;
            case "中雪":
                weather_image_id=R.drawable.biz_plugin_weather_zhongxue;
                break;
            case "中雨":
                weather_image_id=R.drawable.biz_plugin_weather_zhongyu;
                break;
            case "雾":
                weather_image_id=R.drawable.biz_plugin_weather_wu;
                break;
            default:
                weather_image_id=R.drawable.biz_plugin_weather_qing;
                break;
        }
        return weather_image_id;
    }
}
